home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Saar AMOK 2
/
Saar AMOK II - Oktober 1994 (1994)(Kreativ Marketing)(DE)[!][I-7598].iso
/
disks
/
651_700
/
652
/
xpkdisk
/
source.lha
/
mkci.c
< prev
next >
Wrap
C/C++ Source or Header
|
1993-11-08
|
2KB
|
74 lines
/*
* MKCI.C
*
* $Id: mkci.c,v 1.3 1993/11/08 13:11:15 Rhialto Rel $
* $Log: mkci.c,v $
* Revision 1.3 1993/11/08 13:11:15 Rhialto
* Add RCS tags.
*
*
* Generate c.i file for assembly parts to export stuff from C to ASM level.
*/
#include "xpkdisk.h"
#include <exec/resident.h>
#include <stdio.h>
#define OFFSETOF(tag, member) ((long)(&((struct tag *)0)->member))
#define OFFSET(label, structure, member) \
printf("%s\tEQU %d\n", label, OFFSETOF(structure, member))
#define VALUE(label, value) \
printf("%s\tEQU %d\n", label, value);
long
log2(unsigned long x)
{
long log;
if (x) {
for (log = -1; x; log++)
x >>= 1;
return log;
} else {
return -1;
}
}
main(argc, argv)
int argc;
char **argv;
{
if (argc > 1)
freopen(argv[1], "w", stdout);
printf("; Generated by $Id: mkci.c,v 1.3 1993/11/08 13:11:15 Rhialto Rel $\n; Don't edit by hand!\n");
VALUE("xd_SIZEOF", sizeof(DEV));
#ifdef HANDLE_IO_QUICK
VALUE("HANDLE_IO_QUICK", 1);
#else
VALUE("HANDLE_IO_QUICK", 0);
#endif
VALUE("UNITB_ACTIVE", UNITB_ACTIVE);
VALUE("VERSION", VERSION);
VALUE("REVISION", REVISION);
/* Some system include values: */
VALUE("RTC_MATCHWORD", RTC_MATCHWORD);
VALUE("RTF_AUTOINIT", RTF_AUTOINIT);
VALUE("NT_DEVICE", NT_DEVICE);
VALUE("LIBF_CHANGED", LIBF_CHANGED);
VALUE("LIBF_SUMUSED", LIBF_SUMUSED);
OFFSET("ln_Type", Node, ln_Type);
OFFSET("ln_Name", Node, ln_Name);
OFFSET("dev_Flags", XpkDiskDevice, dev_Flags);
OFFSET("dev_Version", XpkDiskDevice, dev_Version);
OFFSET("dev_Revision", XpkDiskDevice, dev_Revision);
OFFSET("dev_IdString", XpkDiskDevice, dev_IdString);
return 0;
}